﻿using System;

namespace SimpleFactory
{
    class Program
    {
        static void Main(string[] args)
        {
            IClustering kmeans = ClusteringFactory.CreateClustering("kmeans");
            Console.WriteLine(kmeans.calculate());

            // 创建Dbscan算法实例
            IClustering dbscan = ClusteringFactory.CreateClustering("dbscan");
            Console.WriteLine(dbscan.calculate());

            // 创建Hierarchical算法实例
            IClustering hierarchical = ClusteringFactory.CreateClustering("hierarchical");
            Console.WriteLine(hierarchical.calculate());

            Console.ReadLine();

        }
    }
}
